package com.example.mitsuki_momo_livestreamingschedule.model;

import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * @author ：lxb
 * @ProjectName: mitsuki_momo_liveStreamingSchedule
 * @Package: com.example.mitsuki_momo_livestreamingschedule.model
 * @ClassName: Event
 * @date ：Created in  2023/3/7 9:33
 * @description：单次直播事件类
 * @version: 1.0
 */

@Data
public class Event {

    @JsonProperty("title")
    public String title;

    @JsonProperty("overview")
    public String overview;

    @JsonProperty("location_url")
    public String location_url;

    @JsonProperty("start_at")
    public long start_at;

    @JsonProperty("end_at")
    public long end_at;

    public String getOverview(){
        return overview = "".equals(overview) ? "@美月もも 直播间" : overview;
    }

    public String getTitle(){
        return title = "配信".equals(title) ? "可爱momo社长开播了！" : title;
    }

}
